package com.lcm.openapi.core.api;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.HashSet;
import java.util.List;
import java.util.Set;

@Data
public class ApiMethod {

    @ApiModelProperty(value = "请求方法")
    private String httpMethod;

    @ApiModelProperty(value = "请求url")
    private String url;

    @ApiModelProperty(value = "接口描述")
    private String summary;

    @ApiModelProperty(value = "详细描述")
    private String description;

    @ApiModelProperty(value = "所属标签")
    private String tags;

    @ApiModelProperty(value = "返回结果类型")
    private String responseEntity;

    @ApiModelProperty(value = "统一返回结果")
    private String response;

    @ApiModelProperty(value = "是否分页")
    private boolean pageResult;

    @ApiModelProperty(value = "分页对象实体")
    private String pageResponseEntity;

    @ApiModelProperty(value = "是否有返回值")
    private boolean responseValue;

    @ApiModelProperty(value = "方法名")
    private String methodName;

    @ApiModelProperty(value = "bodyJson参数")
    private ApiMethodBodyVar bodyJsonVar;

    @ApiModelProperty(value = "bodyMulti参数")
    private List<ApiMethodMultiVar> multiVars;

    @ApiModelProperty(value = "path参数")
    private List<ApiMethodPathVar> pathVars;

    @ApiModelProperty(value = "url参数")
    private List<ApiMethodUrlVar> urlVars;

    @ApiModelProperty(value = "依赖包路径")
    private Set<String> imports = new HashSet<>();

    @ApiModelProperty(value = "依赖的请求对象")
    private Set<String> refRequestModel = new HashSet<>();

    @ApiModelProperty(value = "依赖的返回对象")
    private Set<String> refResponseModel = new HashSet<>();

}
